/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package za.ac.cput.designpatterns.behavioral.templatemethod;

/**
 *
 * @author 210227257
 */
public class MealFactory {
    private static MealFactory mealFactory = null;
    
    private MealFactory(){
        
    }
    
    public synchronized static MealFactory getInstance(){
        if(mealFactory == null){
            mealFactory = new MealFactory();
        }
        return mealFactory;
    }
    
    public Meal getCheeseburgerMeal(){
        return new CheeseburgerMeal();
    }
    
    public Meal getHamburgerMeal(){
        return new HamburgerMeal();
    }
    
}
